package com.Jning.cfengtestdemo.util;

/**
 * @author Cfeng
 * @date 2022/7/25
 */

public class FibonacciUtil {

    public static int compute(int n) {
        int result = 0;
        if(n <= 1) {
            result = n;
        } else {
            result = compute(n -1) + compute(n -2);
        }
        return result;
    }
}
